<%@ page language="java" contentType="text/html; charset=utf-8" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@taglib prefix="spring" uri="http://www.springframework.org/tags" %>

<a href="<c:url value='/u/{{share.user.id}}.do' />">{{ share.user.name }}</a>
<section class="detail wj-detail">
    <p class="default-content wj-default-content txt-xl">{{ share.text }}</p>
    {{# if (share.type == '02') { }}
    {{# if (share.pics.length == 1) { }}
    
    <div class="media-pic">
        <img class="wj-img-s" data-original="{{share.pics[0]}}" src="{{share.pics[0]}}" class="loading">
    </div>
    {{# } else if (share.pics.length > 0) { }}
    <div class="media-pic-list wj-media-pic-list">
        <ul>
            {{# for(var j = 0, len1 = share.pics.length; j < len1; j++){ }}
            <li class="wj-img-s" data-original="{{ share.pics[j] }}" style="background:url({{ share.pics[j] }});background-size: cover;"><img data-original="{{ share.pics[j] }}" src="<c:url value='/img/grey.gif' />" class="loading wj-display-none"></li>
            {{# } }}
        </ul>
    </div>
    {{# } }}
    {{# } else if (share.type == '03' && share.video) { }}
    <div class="media-pic-list">
        <video class="video" poster="" width="296" controls="" preload="">
            <source src="{{ share.video }}" media="only screen and (min-device-width: 296px)">
        </video>
    </div>
    {{# } else if (share.type == '1') {var retweeted = share.retweeted; }}
    <div class="extend-content">
        <div class="inner">
            {{# if (retweeted.id == '-1') { }}
            <p class="original txt-l">{{ retweeted.text }}</p>
            {{# } else { }}
            <p class="original txt-l"><a uid="{{retweeted.user.id}}" href="<c:url value='/u/{{retweeted.user.id}}.do' />">{{retweeted.user.name}}: </a>{{
                retweeted.text }}</p>
            {{# if (retweeted.type == '02') { }}
            {{# if (retweeted.pics.length == 1) { }}
            <div class="media-pic">
                <img class="wj-img-s" data-original="{{retweeted.pics[0]}}" src="{{retweeted.pics[0]}}" class="loading">
            </div>
            {{# } else { }}
            <div class="media-pic-list wj-media-pic-list">
                <ul>
                    {{# for(var j = 0, len1 = retweeted.pics.length; j < len1; j++){ }}
                    <li class="wj-img-s" data-original="{{ retweeted.pics[j] }}" style="background:url( {{ retweeted.pics[j] }} );background-size: cover;"><img data-original="{{ retweeted.pics[j] }}" src="<c:url value='/img/grey.gif' />" class="loading wj-display-none"></li>
                    {{# } }}
                </ul>
            </div>
            {{# } }}
            {{# } else if (retweeted.type == '03' && retweeted.video) { }}
            <div class="media-pic-list">
                <video class="video" poster="" width="296" controls="" preload="">
                    <source src="{{ retweeted.video }}" media="only screen and (min-device-width: 296px)">
                </video>
            </div>
            {{# } }}
            {{# } }}
        </div>
    </div>
    {{# } }}
</section>
{{# if (share.user.id == Page.getUser().id && share.scope != 'public') { }}
<div class="scope">
    {{# if (share.user.id == Page.getUser().id && share.scope == 'private') { }}
    <i class="iconfont private">&#xe61b;</i><span><spring:message code="private"/></span>
    {{# } else if (share.scope == 'enable') { }}
    <i class="iconfont enable">&#xe61c;</i><span><spring:message code="shareList"/></span>
    {{# } else if (share.scope == 'disable') { }}
    <i class="iconfont disable">&#xe61d;</i><span><spring:message code="shareNoList"/></span>
    {{# }}}
</div>
{{# }}}
{{# if (share.address != 0) { }}
<div class="location">
    <i class="iconfont private">&#xe60b;</i><span>{{share.address}}</span>
</div>
{{# }}}
